package com.example.smartgreenhouse.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.time.LocalDateTime;

@Data
@TableName("pump_operation_log")
public class PumpOperationLog {
    @TableId(type = IdType.AUTO)
    private Long id;

    @TableField("pump_id")
    private Long pumpId;

    @TableField("greenhouse_id")
    private Long greenhouseId;

    @TableField("level")
    private String level; // 使用String存储，避免枚举转换问题

    @TableField("operator_id")
    private Long operatorId;

    @TableField("operate_time")
    private LocalDateTime operateTime = LocalDateTime.now();
}